<p><code>sorting</code> - the sorting type to use when rendering the views in this paper (i.e. <q>In what order should the views be rendered?</q>).</p>

<p>The SVG 1.1 format does not have built-in z-index functionality, so JointJS implements it programmatically. You can set the z-index directly using using regular Backbone <code>set('z')</code>/<code>get('z')</code> methods or through <a href="#dia.Element.prototype.toFront"><code>element.toFront()</code></a>/<a href="#dia.Element.prototype.toBack"><code>element.toBack()</code></a>/<a href="#dia.Link.prototype.toFront"><code>link.toFront()</code></a>/<a href="#dia.Link.prototype.toBack"><code>link.toBack()</code></a> methods. See the <a href="#dia.Element.intro.z">element Z documentation</a> for more information.</p>

<p>The Paper object exposes a <code>sorting</code> object with three values that may be used as values of this option:</p>

<ul>
	<li><code>joint.dia.Paper.sorting.EXACT</code> - (default) render views in exactly the same order as reported by <a href="#dia.Graph.prototype.getCells"><code>graph.getCells()</code></a> (views with different z-values are rendered in order, and views with the same z-value are rendered in the order in which they were added). This is by far the slowest option, present mainly for backwards compatibility.</li>
	<li><code>joint.dia.Paper.sorting.APPROX</code> - render views according to their z-values. Views with different z-value are rendered in order, but the ordering of views with the same z-value is indeterminate. Similar in functionality to the <code>EXACT</code> option, but much faster.</li>
	<li><code>joint.dia.Paper.sorting.NONE</code> - render views in an indeterminate order. (Note that this setting disables all <code>toFront</code>/<code>toBack</code> functions mentioned above.)</li>
</ul>
